<?php

namespace App\Http\Controllers;

use App\Models\Prodetails;
use App\Models\Products;
use Illuminate\Http\Request;

class DetailsController extends Controller
{
    public function proDetails($products_id){
        //获取详情图以及缩略图
        $alldetails = Prodetails::where('products_id','=',$products_id)->get();

        $productInfo = Products::where('id','=',$products_id)->get();

        return view('prodetails',['alldetails'=>$alldetails,'productInfo'=>$productInfo]);
    }
}
